Added debugging message to exception on write.
authoremellor@ewan <emellor@ewan>
Tue, 20 Sep 2005 16:19:19 +0000 (17:19 +0100)
committeremellor@ewan <emellor@ewan>
Tue, 20 Sep 2005 16:19:19 +0000 (17:19 +0100)
Signed-off-by: Ewan Mellor <ewan@xensource.com>
tools/python/xen/xend/xenstore/xsnode.py

index 23e39d2969fc17908f7bdba857510118c9a91278..469ef5f536c738c9ab81212b3c690855adc326ac 100644 (file)
@@ -272,8 +272,11 @@ class XenStore:
     def write(self, path, data):
         try:
             self.getxs().write(path, data)
-        except Exception, ex:
-            raise
+        except RuntimeError, ex:
+            raise RuntimeError(ex.args[0],
+                               ex.args[1] +
+                               (', while writing %s : %s' % (str(path),
+                                                             str(data))))
 
     def begin(self, path):
         self.getxs().transaction_start(path)